<section class="section">
  <div class="section-body">
    <div class="row">
      <div class="col-12 col-md-6 col-lg-12">
        <div class="card">
          <div
            class="card-header d-flex justify-content-between align-items-center"
          >
            <h4 class="m-0">投简信息管理</h4>
            <div class="d-flex align-items-center">
              <div class="input-group mr-2" style="width: 600px">
                <select
                  class="form-control"
                  id="searchType"
                  style="width: 120px"
                >
                  <option value="id">ID</option>
                  <option value="companyName">企业名称</option>
                  <option value="jobTitle">岗位名称</option>
                  <option value="seekerName">求职者姓名</option>
                  <option value="seekerEmail">求职者邮箱</option>
                  <option value="status">投简状态</option>
                </select>
                <input
                  type="text"
                  class="form-control"
                  placeholder="输入搜索内容"
                  id="searchInput"
                />
                <div class="input-group-append">
                  <button class="btn btn-primary" type="button" id="searchBtn">
                    <i class="fas fa-search"></i> 查询
                  </button>
                </div>
                <button
                  class="btn btn-danger ml-2"
                  id="batchDeleteBtn"
                  disabled
                >
                  <i class="fas fa-trash"></i> 批量删除
                </button>
              </div>
            </div>
          </div>
          <div class="card-body p-0">
            <div class="table-responsive">
              <table class="table table-striped table-md">
                <thead>
                  <tr>
                    <th>
                      <div class="custom-checkbox custom-control">
                        <input
                          type="checkbox"
                          class="custom-control-input"
                          id="selectAll"
                        />
                        <label
                          for="selectAll"
                          class="custom-control-label"
                        ></label>
                      </div>
                    </th>
                    <th>ID</th>
                    <th>企业名称</th>
                    <th>岗位名称</th>
                    <th>工作类型</th>
                    <th>求职者姓名</th>
                    <th>求职者邮箱</th>
                    <th>投简日期</th>
                    <th>投简状态</th>
                    <th>操作</th>
                  </tr>
                </thead>
                <tbody id="applicationTableBody"></tbody>
              </table>
            </div>
          </div>
          <div class="card-footer text-right">
            <nav class="d-inline-block">
              <ul class="pagination mb-0" id="pagination"></ul>
            </nav>
          </div>
        </div>
      </div>
    </div>
  </div>

  <!-- 投简状态更新模态框 -->
  <div class="modal fade" id="statusModal" tabindex="-1">
    <div class="modal-dialog">
      <div class="modal-content">
        <div class="modal-header">
          <h5 class="modal-title">更新投简状态</h5>
          <button type="button" class="close" id="modalClose">
            <span>&times;</span>
          </button>
        </div>
        <form id="statusForm">
          <div class="modal-body">
            <input type="hidden" id="applicationId" />
            <div class="form-group">
              <label>投简状态</label>
              <select class="form-control" id="status" required>
                <option value="待处理">待处理</option>
                <option value="已查看">已查看</option>
                <option value="已通过">已通过</option>
                <option value="已拒绝">已拒绝</option>
              </select>
            </div>
          </div>
          <div class="modal-footer">
            <button
              type="button"
              class="btn btn-secondary"
              data-dismiss="modal"
            >
              关闭
            </button>
            <button type="submit" class="btn btn-primary">保存</button>
          </div>
        </form>
      </div>
    </div>
  </div>

  <!-- 投简详情模态框 -->
  <div class="modal fade" id="detailModal" tabindex="-1">
    <div class="modal-dialog modal-lg">
      <div class="modal-content">
        <div class="modal-header">
          <h5 class="modal-title">投简详情</h5>
          <button type="button" class="close" data-dismiss="modal">
            <span>&times;</span>
          </button>
        </div>
        <div class="modal-body">
          <div class="row">
            <div class="col-md-6">
              <p><strong>ID:</strong> <span id="detailId"></span></p>
              <p>
                <strong>企业名称:</strong> <span id="detailCompanyName"></span>
              </p>
              <p>
                <strong>岗位名称:</strong> <span id="detailJobTitle"></span>
              </p>
              <p><strong>工作类型:</strong> <span id="detailJobType"></span></p>
              <p>
                <strong>企业联系电话:</strong>
                <span id="detailContactPhone"></span>
              </p>
            </div>
            <div class="col-md-6">
              <p>
                <strong>求职者姓名:</strong> <span id="detailSeekerName"></span>
              </p>
              <p>
                <strong>求职者电话:</strong>
                <span id="detailSeekerPhone"></span>
              </p>
              <p>
                <strong>求职者邮箱:</strong>
                <span id="detailSeekerEmail"></span>
              </p>
              <p>
                <strong>投简日期:</strong>
                <span id="detailApplicationDate"></span>
              </p>
              <p><strong>投简状态:</strong> <span id="detailStatus"></span></p>
            </div>
          </div>
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-secondary" data-dismiss="modal">
            关闭
          </button>
        </div>
      </div>
    </div>
  </div>
</section>
